{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd\n",
    "import numpy as np\n",
    "\n",
    "from sklearn.preprocessing import PolynomialFeatures\n",
    "import statsmodels.api as sm\n",
    "from sklearn.linear_model import LinearRegression\n",
    "\n",
    "import matplotlib.pyplot as plt\n",
    "import seaborn as sns"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "(200, 5)\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Unnamed: 0</th>\n",
       "      <th>TV</th>\n",
       "      <th>radio</th>\n",
       "      <th>newspaper</th>\n",
       "      <th>sales</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>230.1</td>\n",
       "      <td>37.8</td>\n",
       "      <td>69.2</td>\n",
       "      <td>22.1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>44.5</td>\n",
       "      <td>39.3</td>\n",
       "      <td>45.1</td>\n",
       "      <td>10.4</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>17.2</td>\n",
       "      <td>45.9</td>\n",
       "      <td>69.3</td>\n",
       "      <td>9.3</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>4</td>\n",
       "      <td>151.5</td>\n",
       "      <td>41.3</td>\n",
       "      <td>58.5</td>\n",
       "      <td>18.5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>5</td>\n",
       "      <td>180.8</td>\n",
       "      <td>10.8</td>\n",
       "      <td>58.4</td>\n",
       "      <td>12.9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   Unnamed: 0     TV  radio  newspaper  sales\n",
       "0           1  230.1   37.8       69.2   22.1\n",
       "1           2   44.5   39.3       45.1   10.4\n",
       "2           3   17.2   45.9       69.3    9.3\n",
       "3           4  151.5   41.3       58.5   18.5\n",
       "4           5  180.8   10.8       58.4   12.9"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data = pd.read_csv(r'E:\\programming\\dataset\\Into_to_statstical_learning\\Advertising.csv')\n",
    "print(data.shape)\n",
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>TV</th>\n",
       "      <th>radio</th>\n",
       "      <th>newspaper</th>\n",
       "      <th>sales</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>230.1</td>\n",
       "      <td>37.8</td>\n",
       "      <td>69.2</td>\n",
       "      <td>22.1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>44.5</td>\n",
       "      <td>39.3</td>\n",
       "      <td>45.1</td>\n",
       "      <td>10.4</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>17.2</td>\n",
       "      <td>45.9</td>\n",
       "      <td>69.3</td>\n",
       "      <td>9.3</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>151.5</td>\n",
       "      <td>41.3</td>\n",
       "      <td>58.5</td>\n",
       "      <td>18.5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>180.8</td>\n",
       "      <td>10.8</td>\n",
       "      <td>58.4</td>\n",
       "      <td>12.9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      TV  radio  newspaper  sales\n",
       "0  230.1   37.8       69.2   22.1\n",
       "1   44.5   39.3       45.1   10.4\n",
       "2   17.2   45.9       69.3    9.3\n",
       "3  151.5   41.3       58.5   18.5\n",
       "4  180.8   10.8       58.4   12.9"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data = data.iloc[:,1:]\n",
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 52,
   "metadata": {},
   "outputs": [],
   "source": [
    "def fit_degree(data,var,target,degree):\n",
    "    poly = PolynomialFeatures(degree)\n",
    "    poly_data = poly.fit_transform(data[var].to_frame())\n",
    "    lin_model = LinearRegression(fit_intercept=False)\n",
    "    lin_model.fit(poly_data,data[target])\n",
    "    pred = lin_model.predict(poly_data)\n",
    "    \n",
    "    return pred\n",
    "    "
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 1.Is there a relationship between advertising sales and budget?"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### For tv"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "shape -  (200, 2)\n",
      "                            OLS Regression Results                            \n",
      "==============================================================================\n",
      "Dep. Variable:                  sales   R-squared:                       0.612\n",
      "Model:                            OLS   Adj. R-squared:                  0.610\n",
      "Method:                 Least Squares   F-statistic:                     312.1\n",
      "Date:                Thu, 18 Jun 2020   Prob (F-statistic):           1.47e-42\n",
      "Time:                        09:28:34   Log-Likelihood:                -519.05\n",
      "No. Observations:                 200   AIC:                             1042.\n",
      "Df Residuals:                     198   BIC:                             1049.\n",
      "Df Model:                           1                                         \n",
      "Covariance Type:            nonrobust                                         \n",
      "==============================================================================\n",
      "                 coef    std err          t      P>|t|      [0.025      0.975]\n",
      "------------------------------------------------------------------------------\n",
      "const          7.0326      0.458     15.360      0.000       6.130       7.935\n",
      "x1             0.0475      0.003     17.668      0.000       0.042       0.053\n",
      "==============================================================================\n",
      "Omnibus:                        0.531   Durbin-Watson:                   1.935\n",
      "Prob(Omnibus):                  0.767   Jarque-Bera (JB):                0.669\n",
      "Skew:                          -0.089   Prob(JB):                        0.716\n",
      "Kurtosis:                       2.779   Cond. No.                         338.\n",
      "==============================================================================\n",
      "\n",
      "Warnings:\n",
      "[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.\n"
     ]
    }
   ],
   "source": [
    "poly = PolynomialFeatures(1)\n",
    "tv_data = poly.fit_transform(data['TV'].to_frame())\n",
    "print('shape - ',tv_data.shape)\n",
    "est = sm.OLS(data['sales'],tv_data)\n",
    "est2 = est.fit()\n",
    "print(est2.summary())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 55,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAy8AAAHSCAYAAADlvvTeAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4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0gfysRbMkbe9PT4E7htQ5vFO581jK7d/35We0maJcYffqsPuH8uRz3W+W9LC19psDmjh/E6DY/uX8TQ5jzHhjTEP+3xlJf69cbdMfJb0r/7Ch53D/uf0uSR02hAUkDxj+Iclgrd1jjLlE0gpJdZJusdY+GHG3UJsjJP0qXxt2gKRbrbW/M8bcI+lnxpgFkp6S9O4I+4gKGWNuk3SupHHGmE2SLpfUpsL79LeS3qpcIeguSR8KvcOoSJH9e64xZppy6QYbJX1Ekqy1DxpjfibpIeVmOvqYtbYvin6jLLMl/ZOkdfmceUn6vDh/k6LY/r2A8zcxjpL0w/yscCMk/cxa+xtjzEOSfmqMuVJSl3JBrPJ//4cxZoNyIy7vC6OTJoQACQAAAABqlqa0MQAAAAAOI3gBAAAA4ASCFwAAAABOIHgBAAAA4ASCFwAAAABOIHgBAAAA4ASCFwAAAABOIHgBAAAA4IT/D/CtlaqncE9pAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 1008x576 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "pred_1 = fit_degree(data,'TV','sales',1)\n",
    "plt.figure(figsize = (14,8))\n",
    "plt.scatter(data['TV'],data['sales'])\n",
    "plt.plot(data['TV'],pred_1,color = 'orange')\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### For radio"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "shape -  (200, 2)\n",
      "                            OLS Regression Results                            \n",
      "==============================================================================\n",
      "Dep. Variable:                  sales   R-squared:                       0.332\n",
      "Model:                            OLS   Adj. R-squared:                  0.329\n",
      "Method:                 Least Squares   F-statistic:                     98.42\n",
      "Date:                Thu, 18 Jun 2020   Prob (F-statistic):           4.35e-19\n",
      "Time:                        09:30:10   Log-Likelihood:                -573.34\n",
      "No. Observations:                 200   AIC:                             1151.\n",
      "Df Residuals:                     198   BIC:                             1157.\n",
      "Df Model:                           1                                         \n",
      "Covariance Type:            nonrobust                                         \n",
      "==============================================================================\n",
      "                 coef    std err          t      P>|t|      [0.025      0.975]\n",
      "------------------------------------------------------------------------------\n",
      "const          9.3116      0.563     16.542      0.000       8.202      10.422\n",
      "x1             0.2025      0.020      9.921      0.000       0.162       0.243\n",
      "==============================================================================\n",
      "Omnibus:                       19.358   Durbin-Watson:                   1.946\n",
      "Prob(Omnibus):                  0.000   Jarque-Bera (JB):               21.910\n",
      "Skew:                          -0.764   Prob(JB):                     1.75e-05\n",
      "Kurtosis:                       3.544   Cond. No.                         51.4\n",
      "==============================================================================\n",
      "\n",
      "Warnings:\n",
      "[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.\n"
     ]
    }
   ],
   "source": [
    "poly = PolynomialFeatures(1)\n",
    "radio_data = poly.fit_transform(data['radio'].to_frame())\n",
    "print('shape - ',radio_data.shape)\n",
    "est = sm.OLS(data['sales'],radio_data)\n",
    "est2 = est.fit()\n",
    "print(est2.summary())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 67,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAy8AAAHSCAYAAADlvvTeAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAgAElEQVR4nO3de3RV53nv+98rIWBxFTdfEOZiGws7IbYc2eCS9CROE9LmYoX04qQ7ydlJ6zRNGzvbhxzIHme4PXvsA7skddqd7Izj7FzcMersOA1RUrsNzTFO03ogHGHZxo6R7djYsbABAQIDwgjpPX/MJZYk1lpal3l53zm/nzEYgjknWu9amppzPu/zvO9rrLUCAAAAANc1JN0AAAAAAKgEwQsAAAAALxC8AAAAAPACwQsAAAAAL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YrKIu/WUEmhnMHFbHWHsh/PaSg4+RGOXbfymLw8gtJK/Mzb0yVdKukHyfcJvjlx5I+kf/7JyT9KMG2wFH5OvNvSnrGWvvXY3Zx/qAsY8yifMZFxpicpN9SMGbqYUm/mz+McwcXsNZuttYusdYuV/B8s9Na+4fi3EEFjDEzjTGzR/8u6T2SnpJj961MLlJpjPkdBT0RjZK+Za39rwk3CY4yxnxX0jskLZR0UNJdkjol3S9pqaSXJf2etXbioH5knDHmbZL+TdJeFWrPv6hg3AvnD0oyxrxFwaDYRgWdjPdba/9vY8zlCnrT50vqkfQfrLVvJNdSuCxfNvZ/WGvfz7mDSuTPkx/m/zlF0n3W2v9qjFkgh+5bmQxeAAAAAPgni2VjAAAAADxE8AIAAADACwQvAAAAALxA8AIAAADACwQvAAAAALxA8AIAAADACwQvAAAAALxA8AIAAADAC/8/Gqnpnp6WMOoAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 1008x576 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "pred_1 = fit_degree(data,'radio','sales',1)\n",
    "plt.figure(figsize = (14,8))\n",
    "plt.scatter(data['radio'],data['sales'])\n",
    "plt.plot(data['radio'],pred_1,color = 'orange')\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### for newspaper"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "shape -  (200, 2)\n",
      "                            OLS Regression Results                            \n",
      "==============================================================================\n",
      "Dep. Variable:                  sales   R-squared:                       0.052\n",
      "Model:                            OLS   Adj. R-squared:                  0.047\n",
      "Method:                 Least Squares   F-statistic:                     10.89\n",
      "Date:                Thu, 18 Jun 2020   Prob (F-statistic):            0.00115\n",
      "Time:                        09:31:06   Log-Likelihood:                -608.34\n",
      "No. Observations:                 200   AIC:                             1221.\n",
      "Df Residuals:                     198   BIC:                             1227.\n",
      "Df Model:                           1                                         \n",
      "Covariance Type:            nonrobust                                         \n",
      "==============================================================================\n",
      "                 coef    std err          t      P>|t|      [0.025      0.975]\n",
      "------------------------------------------------------------------------------\n",
      "const         12.3514      0.621     19.876      0.000      11.126      13.577\n",
      "x1             0.0547      0.017      3.300      0.001       0.022       0.087\n",
      "==============================================================================\n",
      "Omnibus:                        6.231   Durbin-Watson:                   1.983\n",
      "Prob(Omnibus):                  0.044   Jarque-Bera (JB):                5.483\n",
      "Skew:                           0.330   Prob(JB):                       0.0645\n",
      "Kurtosis:                       2.527   Cond. No.                         64.7\n",
      "==============================================================================\n",
      "\n",
      "Warnings:\n",
      "[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.\n"
     ]
    }
   ],
   "source": [
    "poly = PolynomialFeatures(1)\n",
    "news_data = poly.fit_transform(data['newspaper'].to_frame())\n",
    "print('shape - ',news_data.shape)\n",
    "est = sm.OLS(data['sales'],news_data)\n",
    "est2 = est.fit()\n",
    "print(est2.summary())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 58,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAy8AAAHSCAYAAADlvvTeAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAgAElEQVR4nO3df5TcV33f/9fVamWP/GtlS7KksWUJ28ghKPGSCSUooY7AUggkbNVwKCc/SEpiJ21PE06qVs73j6Snp0fbKk3anrQ2JNBAGygJqAvBNJKxoBBRXFasiQCjWLH54ZFky7bWtqy1vVrd7x+fWY20mpn9fGY+P+6P5+McjtHsfmbuzGdn5vO6933vNdZaAQAAAIDrllTdAAAAAABIg/ACAAAAwAuEFwAAAABeILwAAAAA8ALhBQAAAIAXCC8AA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pdYCZYy5UtInJf2Wtfb5qtuD4hhj3i7pKWvtoQtv7vCrvN/DsVTS6yTda60dlfSiKBELWmuewzskbZS0TtIVSsqGFuJ9Hg8+5yMVU3h5QtKNF/z7BknHKmoLCmSMGVYSXP7MWru3dfOT88PJrf8+VVX7kLstkn7WGPMdJeWgW5WMxIy0yksk3u+heULSE9bah1r//oSSMMP7PFxvkfS4tfaktXZW0l5JbxTv8xh0e19zXRepmMLLVyXd2lqZZJmSiX6frrhNyFlrrsMHJT1irf2DC370aUnvaf3/90j6VNltQzGstfdYa2+w1m5Q8r4+YK39eUmfl/RzrV/jnAfEWntC0veNMZtaN71Z0rfE+zxk35P0BmPM8tbn/Pw5530evm7v609L+qXWqmNvkPTcfHkZwhbVJpXGmJ9W0iM7JOlD1tp/W3GTkDNjzI9L+pKkw2rPf/gdJfNe/lzSeiVfgu+01i6cFAjPGWPukPQvrLVvN8a8SslIzLWSpiT9grX25Srbh/wYY25XskDDMkmPSfoVJR1yvM8DZYz515LepWRVySlJv6pkjgPv80AYYz4m6Q5JKyU9Kel3JU2ow/u6FWL/SMnqZGck/Yq1drKKdqNcUYUXAAAAAP6KqWwMAAAAgMcILwAAAAC8QHgBAAAA4AXCCwAAAAAvEF4AAAAAeIHwAgAAAMALhBcAAAAAXiC8AAAAAPDC/w98K5EZW9y6wwAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 1008x576 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "pred_1 = fit_degree(data,'newspaper','sales',1)\n",
    "plt.figure(figsize = (14,8))\n",
    "plt.scatter(data['newspaper'],data['sales'])\n",
    "plt.plot(data['newspaper'],pred_1,color = 'orange')\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# How strong is the relationship?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "shape -  (200, 4)\n",
      "                            OLS Regression Results                            \n",
      "==============================================================================\n",
      "Dep. Variable:                  sales   R-squared:                       0.897\n",
      "Model:                            OLS   Adj. R-squared:                  0.896\n",
      "Method:                 Least Squares   F-statistic:                     570.3\n",
      "Date:                Thu, 18 Jun 2020   Prob (F-statistic):           1.58e-96\n",
      "Time:                        09:39:07   Log-Likelihood:                -386.18\n",
      "No. Observations:                 200   AIC:                             780.4\n",
      "Df Residuals:                     196   BIC:                             793.6\n",
      "Df Model:                           3                                         \n",
      "Covariance Type:            nonrobust                                         \n",
      "==============================================================================\n",
      "                 coef    std err          t      P>|t|      [0.025      0.975]\n",
      "------------------------------------------------------------------------------\n",
      "constant       2.9389      0.312      9.422      0.000       2.324       3.554\n",
      "TV             0.0458      0.001     32.809      0.000       0.043       0.049\n",
      "radio          0.1885      0.009     21.893      0.000       0.172       0.206\n",
      "newspaper     -0.0010      0.006     -0.177      0.860      -0.013       0.011\n",
      "==============================================================================\n",
      "Omnibus:                       60.414   Durbin-Watson:                   2.084\n",
      "Prob(Omnibus):                  0.000   Jarque-Bera (JB):              151.241\n",
      "Skew:                          -1.327   Prob(JB):                     1.44e-33\n",
      "Kurtosis:                       6.332   Cond. No.                         454.\n",
      "==============================================================================\n",
      "\n",
      "Warnings:\n",
      "[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.\n"
     ]
    }
   ],
   "source": [
    "features = data.iloc[:,:3]\n",
    "columns = ['constant'] + list(features.columns)\n",
    "constant = pd.Series([1]*data.shape[0])\n",
    "features = pd.concat([constant,features],axis = 1)\n",
    "features.columns = columns\n",
    "\n",
    "print('shape - ',features.shape)\n",
    "est = sm.OLS(data['sales'],features)\n",
    "est2 = est.fit()\n",
    "print(est2.summary())"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# which media corresponds to sale?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {},
   "outputs": [],
   "source": [
    "# we can see the p value for the newspaper is very high, but for tv and radio the p value is significant"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 62,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>TV</th>\n",
       "      <th>radio</th>\n",
       "      <th>newspaper</th>\n",
       "      <th>sales</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>TV</th>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.054809</td>\n",
       "      <td>0.056648</td>\n",
       "      <td>0.782224</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>radio</th>\n",
       "      <td>0.054809</td>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.354104</td>\n",
       "      <td>0.576223</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>newspaper</th>\n",
       "      <td>0.056648</td>\n",
       "      <td>0.354104</td>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.228299</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>sales</th>\n",
       "      <td>0.782224</td>\n",
       "      <td>0.576223</td>\n",
       "      <td>0.228299</td>\n",
       "      <td>1.000000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                 TV     radio  newspaper     sales\n",
       "TV         1.000000  0.054809   0.056648  0.782224\n",
       "radio      0.054809  1.000000   0.354104  0.576223\n",
       "newspaper  0.056648  0.354104   1.000000  0.228299\n",
       "sales      0.782224  0.576223   0.228299  1.000000"
      ]
     },
     "execution_count": 62,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "corr_matrix = data.corr()\n",
    "corr_matrix\n",
    "#radio and newpaper are highly correlated"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 34,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "shape -  (200, 3)\n",
      "                            OLS Regression Results                            \n",
      "==============================================================================\n",
      "Dep. Variable:                  sales   R-squared:                       0.897\n",
      "Model:                            OLS   Adj. R-squared:                  0.896\n",
      "Method:                 Least Squares   F-statistic:                     859.6\n",
      "Date:                Thu, 18 Jun 2020   Prob (F-statistic):           4.83e-98\n",
      "Time:                        09:40:01   Log-Likelihood:                -386.20\n",
      "No. Observations:                 200   AIC:                             778.4\n",
      "Df Residuals:                     197   BIC:                             788.3\n",
      "Df Model:                           2                                         \n",
      "Covariance Type:            nonrobust                                         \n",
      "==============================================================================\n",
      "                 coef    std err          t      P>|t|      [0.025      0.975]\n",
      "------------------------------------------------------------------------------\n",
      "constant       2.9211      0.294      9.919      0.000       2.340       3.502\n",
      "TV             0.0458      0.001     32.909      0.000       0.043       0.048\n",
      "radio          0.1880      0.008     23.382      0.000       0.172       0.204\n",
      "==============================================================================\n",
      "Omnibus:                       60.022   Durbin-Watson:                   2.081\n",
      "Prob(Omnibus):                  0.000   Jarque-Bera (JB):              148.679\n",
      "Skew:                          -1.323   Prob(JB):                     5.19e-33\n",
      "Kurtosis:                       6.292   Cond. No.                         425.\n",
      "==============================================================================\n",
      "\n",
      "Warnings:\n",
      "[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.\n"
     ]
    }
   ],
   "source": [
    "#removing newspaper as a feature\n",
    "features = data.iloc[:,:2]\n",
    "columns = ['constant'] + list(features.columns)\n",
    "constant = pd.Series([1]*data.shape[0])\n",
    "features = pd.concat([constant,features],axis = 1)\n",
    "features.columns = columns\n",
    "\n",
    "print('shape - ',features.shape)\n",
    "est = sm.OLS(data['sales'],features)\n",
    "est2 = est.fit()\n",
    "print(est2.summary())"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Is the relationship linear?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "LinearRegression(copy_X=True, fit_intercept=False, n_jobs=None, normalize=False)"
      ]
     },
     "execution_count": 37,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "lin_model = LinearRegression(fit_intercept=False)\n",
    "lin_model.fit(features,data['sales'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([2.92109991, 0.04575482, 0.18799423])"
      ]
     },
     "execution_count": 38,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "lin_model.coef_"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 39,
   "metadata": {},
   "outputs": [],
   "source": [
    "pred = lin_model.predict(features)\n",
    "residual = data['sales'] - pred "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 48,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.lines.Line2D at 0x19c6f1f1320>"
      ]
     },
     "execution_count": 48,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAs8AAAF3CAYAAABaA6YyAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjAsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+17YcXAAAgAElEQVR4nO3de5xcdX3/8fdnd7Nhswkkhk3kEgUVQiPGalYgpFWQi1iimCbVqnitJjS1Kq0aW02lpbYNYC/+WkyCtiAXCxJQwdYASqQGoewSboZGSkESiGQJWchl2c3ufH9/7M6ylzOz35k5Z77nzLyej4c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6749I+n7AtiBG+aBqyBLRfzPLzEzStyQ96pz7+xE/ov9mXKFjS/+NH9U2kDgze40GR5ulwVUtr3POfTVgk1AhM/uOpNMkHS7pWUlfkfQ9STdIepWkpyT9nnOOiWcZU+DYnqbBR75O0pOSVuTzY5EtZvZbkv5L0sOSckMv/7kGc2PpvxlW5Ni+X/TfWBE8AwAAAJ5I2wAAAAA8ETwDAAAAngieAQAAAE8EzwAAAIAngmcAAADAE8EzANQwM7vSzJaFbgcA1AqCZwAAAMATwTMAZMzQqp0/NLMHzewRM3ufmf2Fmd039O/1Q6uNjf27BWb2UzPrNLONI5Zj/rSZbTWzh8zs36u/RQCQHU2hGwAAKNk5kp5xzp0rSWZ2mKTbnXN/NfTvqyUtlnRL/g/MbJKk/yfpPOdcl5m9T9JXJX1c0hclHeuc6zWz6dXdFADIFkaeASB7HpZ0ppmtMbPfds69IOl0M7vXzB6W9HZJrx/zN3MlnSjpdjN7QNKXJR099LOHJF1rZudL6q/OJgBANjHyDAAZ45z7pZktkPQ7kv7WzG6T9EeS2p1z283sIkmHjPkzk/QL59zCiLc8V9JbJb1b0moze71zjiAaACIw8gwAGWNmR0o64Jy7RtJlkt489KPnzGyqpKjqGtsktZnZwqH3mGRmrzezBklznHN3SvqCpOmSpia+EQCQUYw8A0D2vEHSpWaWk3RQ0h9Keo8G0zmelHTf2D9wzvUNlaz7+lCOdJOkf5T0S0nXDL1mkv7BOdddla0AgAwy51zoNgAAAACZQNoGAAAA4IngGQAAAPBE8AwAAAB4IngGAAAAPBE8AwAAAJ4IngEAAABPBM8AAACAJ4JnAAAAwNP/B/0iZ/n+MhtEAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 864x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.figure(figsize = (12,6))\n",
    "plt.ylim(-8, 8)\n",
    "sns.scatterplot(x = data['sales'],y = residual)\n",
    "plt.axhline(y = 0,linestyle = 'dashed',linewidth = 0.5,color = 'red')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 68,
   "metadata": {},
   "outputs": [],
   "source": [
    "# we can see from the graph, that the dispersion is not very well spread, there is some kind of \n",
    "# pattern on the right hand side of the graph"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Is there synergy among the interaction media?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 69,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>TV</th>\n",
       "      <th>radio</th>\n",
       "      <th>newspaper</th>\n",
       "      <th>sales</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>230.1</td>\n",
       "      <td>37.8</td>\n",
       "      <td>69.2</td>\n",
       "      <td>22.1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>44.5</td>\n",
       "      <td>39.3</td>\n",
       "      <td>45.1</td>\n",
       "      <td>10.4</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>17.2</td>\n",
       "      <td>45.9</td>\n",
       "      <td>69.3</td>\n",
       "      <td>9.3</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>151.5</td>\n",
       "      <td>41.3</td>\n",
       "      <td>58.5</td>\n",
       "      <td>18.5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>180.8</td>\n",
       "      <td>10.8</td>\n",
       "      <td>58.4</td>\n",
       "      <td>12.9</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      TV  radio  newspaper  sales\n",
       "0  230.1   37.8       69.2   22.1\n",
       "1   44.5   39.3       45.1   10.4\n",
       "2   17.2   45.9       69.3    9.3\n",
       "3  151.5   41.3       58.5   18.5\n",
       "4  180.8   10.8       58.4   12.9"
      ]
     },
     "execution_count": 69,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 71,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>TV</th>\n",
       "      <th>radio</th>\n",
       "      <th>newspaper</th>\n",
       "      <th>sales</th>\n",
       "      <th>interaction</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>230.1</td>\n",
       "      <td>37.8</td>\n",
       "      <td>69.2</td>\n",
       "      <td>22.1</td>\n",
       "      <td>8697.78</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>44.5</td>\n",
       "      <td>39.3</td>\n",
       "      <td>45.1</td>\n",
       "      <td>10.4</td>\n",
       "      <td>1748.85</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>17.2</td>\n",
       "      <td>45.9</td>\n",
       "      <td>69.3</td>\n",
       "      <td>9.3</td>\n",
       "      <td>789.48</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>151.5</td>\n",
       "      <td>41.3</td>\n",
       "      <td>58.5</td>\n",
       "      <td>18.5</td>\n",
       "      <td>6256.95</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>180.8</td>\n",
       "      <td>10.8</td>\n",
       "      <td>58.4</td>\n",
       "      <td>12.9</td>\n",
       "      <td>1952.64</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      TV  radio  newspaper  sales  interaction\n",
       "0  230.1   37.8       69.2   22.1      8697.78\n",
       "1   44.5   39.3       45.1   10.4      1748.85\n",
       "2   17.2   45.9       69.3    9.3       789.48\n",
       "3  151.5   41.3       58.5   18.5      6256.95\n",
       "4  180.8   10.8       58.4   12.9      1952.64"
      ]
     },
     "execution_count": 71,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data['interaction'] = data['TV']*data['radio']\n",
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 72,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "shape -  (200, 4)\n",
      "                            OLS Regression Results                            \n",
      "==============================================================================\n",
      "Dep. Variable:                  sales   R-squared:                       0.968\n",
      "Model:                            OLS   Adj. R-squared:                  0.967\n",
      "Method:                 Least Squares   F-statistic:                     1963.\n",
      "Date:                Thu, 18 Jun 2020   Prob (F-statistic):          6.68e-146\n",
      "Time:                        11:47:09   Log-Likelihood:                -270.14\n",
      "No. Observations:                 200   AIC:                             548.3\n",
      "Df Residuals:                     196   BIC:                             561.5\n",
      "Df Model:                           3                                         \n",
      "Covariance Type:            nonrobust                                         \n",
      "===============================================================================\n",
      "                  coef    std err          t      P>|t|      [0.025      0.975]\n",
      "-------------------------------------------------------------------------------\n",
      "constant        6.7502      0.248     27.233      0.000       6.261       7.239\n",
      "TV              0.0191      0.002     12.699      0.000       0.016       0.022\n",
      "radio           0.0289      0.009      3.241      0.001       0.011       0.046\n",
      "interaction     0.0011   5.24e-05     20.727      0.000       0.001       0.001\n",
      "==============================================================================\n",
      "Omnibus:                      128.132   Durbin-Watson:                   2.224\n",
      "Prob(Omnibus):                  0.000   Jarque-Bera (JB):             1183.719\n",
      "Skew:                          -2.323   Prob(JB):                    9.09e-258\n",
      "Kurtosis:                      13.975   Cond. No.                     1.80e+04\n",
      "==============================================================================\n",
      "\n",
      "Warnings:\n",
      "[1] Standard Errors assume that the covariance matrix of the errors is correctly specified.\n",
      "[2] The condition number is large, 1.8e+04. This might indicate that there are\n",
      "strong multicollinearity or other numerical problems.\n"
     ]
    }
   ],
   "source": [
    "features = data.drop(['newspaper','sales'],axis = 1)\n",
    "columns = ['constant'] + list(features.columns)\n",
    "constant = pd.Series([1]*data.shape[0])\n",
    "features = pd.concat([constant,features],axis = 1)\n",
    "features.columns = columns\n",
    "\n",
    "\n",
    "print('shape - ',features.shape)\n",
    "est = sm.OLS(data['sales'],features)\n",
    "est2 = est.fit()\n",
    "print(est2.summary())"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## We can see that by just adding the interaction term we have got the R2 value of almost 97"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
